package com.team5101.service.impl;

import com.team5101.dao.ICartDao;
import com.team5101.entity.Cart;
import com.team5101.entity.CartDTO;
import com.team5101.service.ICartService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
 @Service
public class CartServiceImpl implements ICartService {


     @Autowired
     private ICartDao cartDao;


    public List<CartDTO> quryUserCartDTO(Integer uid) {

        return cartDao.quryUserCartDTO(uid);


    }

     public int deleteByCartId(Integer cId) {
         return cartDao.deleteByCartId(cId);
     }

     public int addCart(Cart cart) {
         return cartDao.addCart(cart);
     }


 }
